package com.wxd.config;

import com.wxd.interceptor.BaseInterceptor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurationSupport;

/**
 * @author wxd
 * @version V1.0
 * @description WebAuthConfig
 * @date 2022/10/11 11:11
 **/
//@Configuration
public class WebAuthConfig extends WebMvcConfigurationSupport {

    @Bean
    public BaseInterceptor getBaseInterceptor() {
        return new BaseInterceptor();
    }

    @Override
    public void addInterceptors(InterceptorRegistry registry) {
        registry.addInterceptor(new BaseInterceptor());
    }

}
